home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
How Would You Survive?
/
How Would You Survive (1995)(Grolier)[Mac-PC].iso
/
pc
/
fquit.dir
/
00040_Script_a2StateButton
< prev
Wrap
Text File
|
1995-09-06
|
1KB
|
65 lines
property pSprite,pCast,pNutral,pDepressed,pFunction,pMySound,pCursor
on birth me,theSprite,theCast,aSound,aFunction,aCursor
set pSprite = theSprite
set pcursor = aCursor
set pCast = theCast
set pMySound = aSound
set pNutral = pCast
set pDepressed = pCast + 1
set pFunction = aFunction
puppetSprite pSprite,TRUE
set the castNum of sprite pSprite = pCast
return me
end
on setNewFunction me, aFunction
set pFunction = aFunction
end
on setNewSound me, aNewSound
set pMySound = aNewSound
end
on reset me
set the castNum of sprite pSprite = pNutral
updatestage
end
on hilight me
puppettransition 0
if (rollover(pSprite)) then
if (the mouseDown) then
puppetsound pMySound
DepressedState(me)
wait .2
reset(me)
do pFunction
else
reset(me)
end if
end if
reset(me)
end
on hideControl me
puppetSprite pSprite, FALSE
end
on showControl me
puppetSprite pSprite,TRUE
end
on changeBaseButton me, newBase
set pCast = newBase
set pDepressed = pCast + 1
set the castNum of sprite pSprite = pCast
end
on DepressedState me
set the castNum of sprite pSprite = pDepressed
Updatestage
end